﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;

namespace MyTest
{
    /// <summary>
    /// 教员:薛海
    /// 微信:xuehai03
    /// QQ:289477003
    /// 数制转换
    /// 2019-2-20
    /// </summary>
    public partial class frmShuZi : Form
    {
        public frmShuZi()
        {
            InitializeComponent();
        }

        private void textBox1_TextChanged(object sender, EventArgs e)
        {
            int str =Convert.ToInt32( this.txtNum1.Text);

            this.textBox2.Text = Convert.ToString(str,16);

        }

        private void textBox3_TextChanged(object sender, EventArgs e)
        {
            int str = Convert.ToInt32(this.txtNum2.Text);

            this.textBox1.Text = Convert.ToString(str, 2);
        }
    }
}
